package cn.bq;

import java.util.concurrent.BlockingQueue;

public class Producer extends Thread {
    private BlockingQueue<Food> bqueue;
	public Producer(BlockingQueue<Food> queue){
		this.bqueue=queue;
	}
	@Override
	public void run(){
		while(true){
			try {
				bqueue.put(new Food());
			} catch (InterruptedException e) {
				e.printStackTrace();
			}
			System.out.println("put one");
		}
	}
}
